<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script>

     var a = parseInt(prompt("输入一个数"));
     var b = parseInt(prompt("输入二个数"));
     var c = prompt("输入一个符号(+-*/)");
     if(c="+"){
         d=a+b;
     }
     if(c="-"){
         d=a-b;
     }
     if(c="*"){
         d=a*b;
     }
     if(c="/"){
         d=a/b;
     }
     if(c="%"){
         d=a%b;
     }

    alert(d);
</script>

</body>
</html>